﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Markup;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.Collections.ObjectModel;

namespace UI.Navigations.Maps
{
    [TemplatePart(Name=Part_LicenseContainer, Type=typeof(Panel))]
    [TemplatePart(Name = Part_MapContent, Type = typeof(Grid))]
    [TemplatePart(Name = Part_MapLayers, Type = typeof(Grid))]
    [TemplatePart(Name = Part_MapRotation, Type = typeof(RotateTransform))]
    [TemplatePart(Name = Part_MouseControl, Type = typeof(MouseControl))]
    [ContentProperty("Layers")]
    public class Map:Control
    {
        #region const 
        private const string Part_LicenseContainer = "Part_LicenseContainer";
        private const string Part_MapContent = "Part_MapContent";
        private const string Part_MapLayers = "Part_MapLayers";
        private const string Part_MapRotation = "Part_MapRotation";
        private const string Part_MouseControl = "Part_MouseControl";
        #endregion

        #region drag behavior
        public enum MapDragBehavior
        {
            Pan,Select,Draw
        }
        #endregion

        #region fields

        private static Map DefaultInstance;
        private readonly ObservableCollection<IMapLayer> _Layers;
        private readonly TileLayer _TileLayer;

        private DoubleAnimation _AnimationMapAngle;
        private CoordTransform _CoordHelper;
        private MapDragBehavior _DragMode = MapDragBehavior.Pan; 
        #endregion
    }
}
